package com.myway.service.ibe.config;

/**
 * Created by Administrator on 2018/1/15.
 */
public class IBEClientConfig {
    /**
     * IBE 服务器 IP地址
     */
    private String ip;
    /**
     * IBE 备份IP地址
     */
    private String backupIp;
    /**
     * IBE 服务器 端口
     */
    private String port;
    /**
     * 应用程序
     */
    private String app;
    /**
     * Office号
     */
    private String office;
    /**
     * 客户号
     */
    private String customno;
    /**
     * 验证码
     */
    private String validationno;

    /**
     * 打票机号多个用,分割
     * myway:1纸票打票机
     */
    private String printNos="2";

    private String printInterNos="6";

    public IBEClientConfig() {

    }

    public String getIp() {
        return ip;
    }

    public void setIp(String ip) {
        this.ip = ip;
    }

    public String getBackupIp() {
        return backupIp;
    }

    public void setBackupIp(String backupIp) {
        this.backupIp = backupIp;
    }

    public String getPort() {
        return port;
    }

    public void setPort(String port) {
        this.port = port;
    }

    public String getApp() {
        return app;
    }

    public void setApp(String app) {
        this.app = app;
    }

    public String getOffice() {
        return office;
    }

    public void setOffice(String office) {
        this.office = office;
    }

    public String getCustomno() {
        return customno;
    }

    public void setCustomno(String customno) {
        this.customno = customno;
    }

    public String getValidationno() {
        return validationno;
    }

    public void setValidationno(String validationno) {
        this.validationno = validationno;
    }

    public String getPrintNos() {
        return printNos;
    }

    public void setPrintNos(String printNos) {
        this.printNos = printNos;
    }

    public String getPrintInterNos() {
        return printInterNos;
    }

    public void setPrintInterNos(String printInterNos) {
        this.printInterNos = printInterNos;
    }

    @Override
    public String toString() {
        return "IBEClientConfig{" +
                "ip='" + ip + '\'' +
                ", backupIp='" + backupIp + '\'' +
                ", port='" + port + '\'' +
                ", app='" + app + '\'' +
                ", office='" + office + '\'' +
                ", customno='" + customno + '\'' +
                ", validationno='" + validationno + '\'' +
                ", printNos='" + printNos + '\'' +
                ", printInterNos='" + printInterNos + '\'' +
                '}';
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        IBEClientConfig that = (IBEClientConfig) o;

        if (ip != null ? !ip.equals(that.ip) : that.ip != null) return false;
        if (backupIp != null ? !backupIp.equals(that.backupIp) : that.backupIp != null) return false;
        if (port != null ? !port.equals(that.port) : that.port != null) return false;
        if (app != null ? !app.equals(that.app) : that.app != null) return false;
        if (office != null ? !office.equals(that.office) : that.office != null) return false;
        if (customno != null ? !customno.equals(that.customno) : that.customno != null) return false;
        if (validationno != null ? !validationno.equals(that.validationno) : that.validationno != null) return false;
        if (printNos != null ? !printNos.equals(that.printNos) : that.printNos != null) return false;
        return printInterNos != null ? printInterNos.equals(that.printInterNos) : that.printInterNos == null;

    }

    @Override
    public int hashCode() {
        int result = ip != null ? ip.hashCode() : 0;
        result = 31 * result + (backupIp != null ? backupIp.hashCode() : 0);
        result = 31 * result + (port != null ? port.hashCode() : 0);
        result = 31 * result + (app != null ? app.hashCode() : 0);
        result = 31 * result + (office != null ? office.hashCode() : 0);
        result = 31 * result + (customno != null ? customno.hashCode() : 0);
        result = 31 * result + (validationno != null ? validationno.hashCode() : 0);
        result = 31 * result + (printNos != null ? printNos.hashCode() : 0);
        result = 31 * result + (printInterNos != null ? printInterNos.hashCode() : 0);
        return result;
    }
}
